package com.jm.service;


import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.jm.common.util.entity.SelectCondition;
import com.jm.pojo.Setmeal;
import com.jm.pojo.dto.SetmealDto;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Transactional
public interface SetmealService extends IService<Setmeal> {

    IPage<Setmeal> selectByPageCondition(SelectCondition condition);

    boolean changeStatusByIds(List<String> ids, Integer status);

    List<Setmeal> getByCategoryId(String categoryId);

    boolean saveWithSetmealToy(SetmealDto setmealDto);

    SetmealDto selectWithToy(Long id);

    boolean updateWithDish(SetmealDto setmealDto);

    SetmealDto getDtoBySetmealId(Long setmealId);

    SetmealDto toDto(Setmeal setmeal);

    IPage<SetmealDto> toDto(IPage<Setmeal> setmealIPage);
}
